package www.openteam.com.workorder;


import www.openteam.com.bean.Inputer;
import www.openteam.com.bean.MachineInfo;
import www.openteam.com.bean.PDistrubition;
import www.openteam.com.bean.UpdateInfo;
import www.openteam.com.bean.WorkOrder;
import www.openteam.com.bean.WorkOrder2;

/**
 * Created by kylin on 2017/5/2.
 */

public class BaseWorkOrderContract {


    public interface WorkOrderView {

        String getStype();

        String getMoreCom();

        String getName();

        String getCode();

        void queryISuccess(Inputer inputer);

        void queryIFail(String failMsg);

        void queryWSuccess(WorkOrder2 workOrder);

        void queryWFail(String failMsg);

        void findMSuccess(MachineInfo machineInfo);

        void findMFail(String failMsg);


        void updateTSSuccess(UpdateInfo updateInfo);

        void updateTSFail(String fail);

        void findWPSuccess(PDistrubition pDistrubition);

        void findWPFail(String fail);

        void insertSPSuccess(UpdateInfo info);

        void insertSPFail(String fail);

        void insertEPSuccess(UpdateInfo info);

        void insertEPFail(String fail);

    }

    public interface WorkOrderPresenter {

        void queryUserIsExist(String name);

        void queryWO(
                String barCode
                , String stype
                , String morecom
                , int proCode
        );


        void findMachine(String code, String inputer, String processid,
                         String rdsno, String stype, String morecom);

        void updateTimeStatus(String zbid,
                              String procno,
                              String id,
                              String e_Time, String stype, String morecom);

        void findWorkPrice(
                String machinecode,
                String banzu
                , String peopleGroup, String stype, String morecom
        );


        /**
         * @param InputDate 建单日期
         * @param zbid      生产工程单id
         * @param rdsno     工单编号
         * @param orderno   订单编号
         * @param custid    客户id
         * @param StartTime 开始时间
         * @param PartID    部件id
         * @param PrdID     生产工程单工序id
         * @param TolNumb   应产数
         * @param code      产品编号
         * @param Inputer   錄入员
         * @param UserID    登录的用户id
         * @param MachinID  机台编号
         * @param procno    工序编号
         * @return
         */
        void insertSProductionInfo(
                long InputDate,
                String zbid,
                String rdsno,
                String orderno,
                String custid,
                long StartTime,
                String PartID,
                String PrdID,
                double TolNumb,
                String code,
                String Inputer,
                String UserID,
                String MachinID,
                String BuilderName,
                String InputerName,
                String procno, String stype, String morecom
        );


        /**
         * @param groupA     人组数据
         * @param isFinish   是否完成
         * @param rdsno      工单编号
         * @param GroupCount 人组
         * @param zbid       生产工程单id
         * @param OverDate   完成日期
         * @param EndTime    结束日期
         * @param PrdID      生产工程单工序id
         * @param Numb1      车头数
         * @param MachinID   机台编号
         * @param code       产品编号
         * @param Inputer    錄入员
         * @param procno     工序编号
         * @return
         */


        void insertEProductionInfo(
                String groupA,
                boolean isFinish,
                String rdsno,
                String GroupCount,
                String zbid,
                long OverDate,
                long EndTime,
                String PrdID,
                double Numb1,
                String MachinID,
                String code,
                String Inputer,
                String procno,
                String custid,
                String orderno,
                double TolNumb,
                String PartID,
                String BuilderName,
                String InputerName,
                int userid,
                int id,
                String banzu, String stype, String morecom,
                String remark

        );


    }
}
